// 蜂窝蜜造平台生成代码，如手工更改，请添加到 .beeignore 忽略生成

package com.fowo.api.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.fowo.api.common.model.OptionItem;
import com.fowo.api.common.model.PageSearch;
import com.fowo.api.entity.BatchFlow;
import com.fowo.api.model.batch.flow.BatchFlowCustAlldataParams;
import com.fowo.api.model.batch.flow.BatchFlowCustAlldataResult;
import com.fowo.api.model.batch.flow.BatchFlowItemVo;
import com.fowo.api.model.batch.flow.BatchFlowSearchParamPo;
import com.fowo.api.model.batch.flow.BatchFlowVo;
import java.util.Date;
import java.util.List;
import java.util.Map;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

@Mapper
public interface BatchFlowMapper extends BaseMapper<BatchFlow> {
  Page<BatchFlowItemVo> pageSearch(
    @Param("page") Page page,
    @Param("search") BatchFlowSearchParamPo search
  );
  List<OptionItem<BatchFlowItemVo>> searchOptions(
    @Param("search") BatchFlowSearchParamPo search
  );
  List<BatchFlowItemVo> search(@Param("search") BatchFlowSearchParamPo search);
  Date searchLastUpdateTime(@Param("search") BatchFlowSearchParamPo search);
  /**
   * 搜索满足条件的所有记录的编号列表
   * @param search 搜索参数
   * @return 编号列表
   */
  List<Long> searchIds(@Param("search") BatchFlowSearchParamPo search);
  /**
   * 搜索满足条件的记录数量
   * @param search 搜索参数
   * @return 记录数量
   */
  Long searchCount(@Param("search") BatchFlowSearchParamPo search);
  Long getIdByBatchNumber(@Param("batchNumber") String batchNumber);

  List<Long> getIdsByBatchNumber(@Param("list") List<String> list);

  String getBatchNumberById(@Param("id") Long id);

  List<Map<String, Object>> getBatchNumberByIds(@Param("ids") List<Long> ids);
  BatchFlowVo selectVoById(@Param("id") Long id);
  /**
   * 全部 总数
   */
  int CustAlldataTotal(@Param("params") BatchFlowCustAlldataParams params);

  /**
   * 全部（分页）
   */

  @SuppressWarnings("MybatisXMapperMethodInspection")
  List<List<?>> custAlldataPage(
    @Param("params") BatchFlowCustAlldataParams params
  );

  /**
   * 查询仓库下拉框
   */
  @SuppressWarnings("MybatisXMapperMethodInspection")
  List<Map> custAlldatawarehouseId();

  /**
   * 查询店铺下拉框
   */
  @SuppressWarnings("MybatisXMapperMethodInspection")
  List<Map> custAlldatashopId();
}
